package com.sl.au.service;

import java.util.List;
import java.util.Map;

import com.sl.au.entity.Division;
import com.sl.au.entity.EventType;
import com.sl.au.repository.EventTypeRepository;

public interface EventTypeService extends BaseService {

	EventTypeRepository getRepository();

	/**
	 * 转换树结构
	 * 
	 * @param node
	 * @return
	 */
	List<Map<String, Object>> getNodeMap(List<EventType> node);

	public List<EventType> getAllNodes();

	/*********** 获取未绑定节点 *************/

	List<EventType> getEventTypeByKey(int start, int length, String key, String orderName, String dir);

	long getEventTypeByKeyCount(String key);

	/************ 获取子节点 ************/

	List<EventType> getChildrenEventTypeByKey(int start, int length, String id, String key, String orderName,
			String dir);

	int getChildrenEventTypeByKeyCount(String id, String key);

	/**********************************/

	/**
	 * 删除节点
	 *
	 * @param ids
	 * @return
	 */
	void deleteNodes(String[] ids);

	void setEventTypeOrder(String parent);

	String getEventTypeIdentify(String id);

	List<EventType> findOuterTypeOnlyCon(int start, int length, String con);

	int findOuterTypeCountOnlyCon(String con);

	List<EventType> findOuterTypeNone(int start, int length);

	int findOuterTypeCountNone();

	List<EventType> findOuterTypeByKeyAndCon(int start, int length, String key, String con);

	int findOuterTypeCountByKeyAndCon(String key, String con);

	List<EventType> findOuterTypeOnlyKey(int start, int length, String key);

	int findOuterTypeCountOnlyKey(String key);

	List<EventType> findInnerTypeOnlyCon(int start, int length, String con);

	int findInnerTypeCountOnlyCon(String con);

	List<EventType> findInnerTypeNone(int start, int length);

	int findInnerTypeCountNone();

	int findInnerTypeCountByKeyAndCon(String key, String con);

	List<EventType> findInnerTypeByKeyAndCon(int start, int length, String key, String con);

	List<EventType> findInnerTypeOnlyKey(int start, int length, String key);

	int findInnerTypeCountOnlyKey(String key);

	List<EventType> findByParentId(String parentId);
}
